#ifndef READ_BOY_BASE_H__
#define READ_BOY_BASE_H__
#include "hardware/spi.h"
#include "pico/stdlib.h"

#define LOW 0
#define HIGH 1



#define EPD_RST_PIN 17
#define EPD_CS_PIN 19
#define EPD_DC_PIN 18
#define EPD_BUSY_PIN 16
#define EPD_CLK_PIN 22
#define EPD_MOSI_PIN 23


void DigitalWrite(uint16_t Pin, uint8_t Value);
void readboyEpdBase_GPIOInit(void);
void DelayMs(uint32_t xms);
void Delayus(uint32_t xus);

void readboyEpdBase_Reset(uint32_t minTime);
void readboyEpdBase_BeginTransfer();
void readboyEpdBase_EndTransfer();
void readboyEpdBase_boy_epdCmd(unsigned char command);
void readboyEpdBase_boy_epdParam(unsigned char data);
void readboyEpdBase_SetMemory();
void readboyEpdBase_boy_epdBusy(int32_t maxt);
void SpiTransfer(uint8_t Value);

void my_readboyEpdBase_init();
#endif